package org.dreamwork.hyacinth;

import javax.mail.Authenticator;
import javax.mail.PasswordAuthentication;

/**
 * Created by IntelliJ IDEA.
 * User: seth
 * Date: 2010-4-26
 * Time: 13:23:59
 */
public class PasswordAuthenticator extends Authenticator {
    private String userName, password;

    public PasswordAuthenticator (String name, String password) {
        this.userName = name;
        this.password = password;
    }

    @Override
    protected PasswordAuthentication getPasswordAuthentication () {
        return new PasswordAuthentication (userName, password);
    }
}